package mygame;

import com.jme3.app.SimpleApplication;
import com.jme3.niftygui.NiftyJmeDisplay;
import com.jme3.renderer.RenderManager;
import test4.menus.MainMenuManager;

public class Main extends SimpleApplication {

    private MainMenuManager mainMenuManager;

    public static void main(String[] args) {
        Main app = new Main();
        app.start();
    }

    public void simpleInitApp() {

        mainMenuManager = new MainMenuManager();
        mainMenuManager.startNifty(new NiftyJmeDisplay(assetManager, inputManager,
                                                    audioRenderer, guiViewPort)); // executes main menu nifty gui

        // attach the nifty display to the gui view port as a processor
        guiViewPort.addProcessor(mainMenuManager.getNiftyJmeDisplay());

//        disable the fly cam
//        flyCam.setEnabled(false);
        flyCam.setDragToRotate(true);
    }

    @Override
    public void simpleUpdate(float tpf) {
        //TODO: add update code
    }

    @Override
    public void simpleRender(RenderManager rm) {
        //TODO: add render code
    }
}
